Current Location: Home> Function Categories> deg2rad

deg2rad

Convert angle to radians
Name:deg2rad
Category:math
Programming Language:php
One-line Description:Convert angle to radians.

Definition and usage

deg2rad() function converts angles to radians.

Example

Example 1

 <?php
echo deg2rad ( "30" ) ;
echo deg2rad ( "10" ) ;
echo deg2rad ( "1587" ) ;
echo deg2rad ( "70" ) ;
?>

Try it yourself

Example 2

 <?php
$deg = 180 ;
$rad = deg2rad ( $deg ) ;
echo "angle $deg equals radian $rad " ;
?>

Try it yourself

grammar

 deg2rad ( degree_number )
parameter describe
degree_number Required. Specify the angle to be converted.

illustrate

This function converts degree_number from angle to radian.

Similar Functions
  • Find the minimum value min

    min

    Findtheminimumvalue
  • Hyperbolic cosine cosh

    cosh

    Hyperboliccosine
  • Logarithm with base 10 log10

    log10

    Logarithmwithbase10
  • Generate a random integer rand

    rand

    Generatearandominteg
  • Cosine cos

    cos

    Cosine
  • Anyway atan

    atan

    Anyway
  • Show the maximum possible value of random number getrandmax

    getrandmax

    Showthemaximumpossib
  • Perform floating point division under IEEE 754 semantics fdiv

    fdiv

    Performfloatingpoint
Popular Articles